<?php
require_once SOURCE_EXT_PATH.'library/SessionBase.php';
class AdminSession
{
	private static $rootKey = 'admin';

	public static function setAdminInfo($value)
	{
		SessionBase::setSession(self::$rootKey, 'AdminSessionInfo', $value);
	}

	/**
	 * @return AdminSessionInfo
	 */
	public static function getAdminSessionInfo()
	{
		return SessionBase::getSession(self::$rootKey, 'AdminSessionInfo');
	}

	public static function clear()
	{
		SessionBase::clearSession(self::$rootKey);
	}
	
	public static function setCaptcha($value){
		SessionBase::setSession(self::$rootKey, 'captcha', $value);
	}
	
	public static function getCaptcha()
	{
		return SessionBase::getSession(self::$rootKey,'captcha');
		
	}

	public static function clearCaptcha()
	{
		SessionBase::clearSession(self::$rootKey,'captcha');
	}
}